package Entity;

import Control.MySQLController;

public class NeedyResident_DeleteAccount extends User{
	
	public boolean deleteResident(){
		boolean dsuccess = false;
		MySQLController db = new MySQLController();
		db.getConnection();
		//Set status code in database to 'D'
		String sql = "UPDATE ooadpj.user SET user_status_code = 'D'";
		sql +="WHERE nric ='" + getNric() + "'";
		if(db.updateRequest(sql)==1)
			dsuccess = true;
		db.terminate();
		return dsuccess;
	}
}
